﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Index.aspx.cs" Inherits="Tools_CreateUI_Index" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
    <style type="text/css">
        .table { border-collapse: collapse; font-family: Arial,"宋体"; font-size: 12px; width: 100%; }
        .table td { border-collapse: collapse; border: solid 1px #B5D6E6; padding: 3px 0 3px 6px; font-family: Tahoma,"宋体"; font-size: 12px; line-height: 22px; }
        .table th { border-collapse: collapse; border: solid 1px #B5D6E6; padding: 3px 0 3px 6px; font-family: Tahoma,"宋体"; font-size: 12px; background-color: #CBE0F5; line-height: 22px; }
        .table td a, th a { text-decoration: none; font-weight: normal; padding-left: 3px; text-align: left; }
    </style>
</head>
<body>
    <form id="form1" runat="server">
        <asp:Repeater ID="Repeater1" runat="server">
            <HeaderTemplate>
                <table class="table">
                    <tr>
                        <th width="30px">id</th>
                        <th width="30px">box</th>
                        <th width="60px">主键</th>
                        <th width="150px">字段</th>
                        <th>注释</th>
                        <th style="text-align: left; font-weight: normal;">
                            <input id="Checkbox1" type="checkbox" disabled />自动
                            <input id="Checkbox首页显示" type="checkbox" onclick="chx('首页显示');" />首页显示
                            <input id="Checkbox整数搜索" type="checkbox" onclick="chx('整数搜索');" />整数搜索
                            <input id="Checkbox必填" type="checkbox" onclick="chx('必填');" />必填
                            <input id="Checkbox编辑器" type="checkbox" onclick="chx('编辑器');" />编辑器
                            <input id="Checkbox整数" type="checkbox" onclick="chx('整数');" />整数
                        </th>
                    </tr>
            </HeaderTemplate>
            <AlternatingItemTemplate>
                <tr onmouseover="this.style.backgroundColor='Ivory'" onmouseout="this.style.backgroundColor='#ffffff'" style="background-color: #ffffff;">
                    <td style="color: Gray;"><%# (Repeater1.Items.Count + 1) < 10 ? "0" + (Repeater1.Items.Count + 1).ToString() : (Repeater1.Items.Count + 1).ToString() %>
                        <td>
                            <asp:CheckBox ID="CheckBox2" runat="server" />
                        </td>
                        <td>
                            <%# Eval("IsPrimaryKey").ToString()=="1"?"主键":"" %>
                            <asp:Literal ID="类型Literal" runat="server" Text='<%# Eval("Type") %>' Visible="false" />
                        </td>
                        <td>
                            <asp:Literal ID="字段Literal" runat="server" Text='<%# Eval("Name")%>' /></td>
                        <td>
                            <asp:Literal ID="注释Literal" runat="server" Text='<%# Eval("Comments")%>' /></td>
                        <td style="display: block;">
                            <asp:CheckBox ID="自动CheckBox" runat="server" Text="自动" AutoPostBack="true" />
                            <asp:CheckBox ID="首页显示CheckBox" runat="server" Checked="false" Text="首页显示" name="home" />
                            <asp:CheckBox ID="整数搜索CheckBox" runat="server" Text="整数搜索" />
                            <asp:CheckBox ID="必填CheckBox" runat="server" Text="必填" />
                            <asp:CheckBox ID="编辑器CheckBox" runat="server" Text="编辑器" />
                            <asp:CheckBox ID="邮箱CheckBox" runat="server" Text="邮箱" Visible="false" />
                            <asp:CheckBox ID="整数CheckBox" runat="server" Text="整数" />
                            <asp:CheckBox ID="字典CheckBox" runat="server" Text="字典" />
                            <asp:TextBox ID="字典TextBox" runat="server" Width="45px" Visible="false"></asp:TextBox>
                        </td>
                </tr>
            </AlternatingItemTemplate>
            <ItemTemplate>
                <tr onmouseover="this.style.backgroundColor='Ivory'" onmouseout="this.style.backgroundColor='#F2F7FC'" style="background-color: #F2F7FC;">
                    <td style="color: Gray;"><%# (Repeater1.Items.Count + 1) < 10 ? "0" + (Repeater1.Items.Count + 1).ToString() : (Repeater1.Items.Count + 1).ToString() %>
                        <td>
                            <asp:CheckBox ID="CheckBox2" runat="server" />
                        </td>
                        <td>
                            <%# Eval("IsPrimaryKey").ToString()=="1"?"主键":"" %>
                            <asp:Literal ID="类型Literal" runat="server" Text='<%# Eval("Type") %>' Visible="false" />
                        </td>
                        <td>
                            <asp:Literal ID="字段Literal" runat="server" Text='<%# Eval("Name")%>' /></td>
                        <td>
                            <asp:Literal ID="注释Literal" runat="server" Text='<%# Eval("Comments")%>' /></td>
                        <td style="display: block;">
                            <asp:CheckBox ID="自动CheckBox" runat="server" Text="自动" AutoPostBack="true" />
                            <asp:CheckBox ID="首页显示CheckBox" runat="server" Checked="false" Text="首页显示" />
                            <asp:CheckBox ID="整数搜索CheckBox" runat="server" Text="整数搜索" />
                            <asp:CheckBox ID="必填CheckBox" runat="server" Text="必填" />
                            <asp:CheckBox ID="编辑器CheckBox" runat="server" Text="编辑器" />
                            <asp:CheckBox ID="邮箱CheckBox" runat="server" Text="邮箱" Visible="false" />
                            <asp:CheckBox ID="整数CheckBox" runat="server" Text="整数" />
                            <asp:CheckBox ID="字典CheckBox" runat="server" Text="字典" />
                            <asp:TextBox ID="字典TextBox" runat="server" Width="45px" Visible="false"></asp:TextBox>
                        </td>
                </tr>
            </ItemTemplate>
            <FooterTemplate>
                </table>
            </FooterTemplate>
        </asp:Repeater>

        <table style="background-color: #F2F7FC; margin-top: 10px; margin-bottom: 10px; width: 100%;" class="table">
            <%-- <tr>
                <td style="width: 100px; text-align: right;">命名空间：</td>
                <td>
                    <asp:TextBox ID="命名空间TextBox" runat="server" Width="300px" Text="DZHJ.view" /></td>
            </tr>--%>
            <tr>
                <td style="width: 100px; text-align: right;">文件名：</td>
                <td>
                    <asp:TextBox ID="文件名TextBox" runat="server" Width="300px" /></td>
            </tr>
            <tr>
                <td style="width: 100px; text-align: right;">标题头：</td>
                <td>
                    <asp:TextBox ID="标题头TextBox" runat="server" Width="300px" /></td>
            </tr>
            <tr>
                <td style="width: 100px; text-align: right;">文件路径：</td>
                <td>
                    <asp:TextBox ID="文件路径TextBox" runat="server" Width="650px" /></td>
            </tr>
            <tr>
                <td style="width: 100px; text-align: right;"></td>
                <td>
                    <asp:Button ID="效验Button" runat="server" Text="效验是否存在" OnClick="效验Button_Click" />
                    &nbsp;&nbsp;&nbsp;
                    <asp:Button ID="生成Button" runat="server" Text="生成代码" OnClick="生成Button_Click" Style="margin-bottom: 0px" />&nbsp;
                    <asp:Literal ID="信息Literal" runat="server" />
                </td>
            </tr>
        </table>
    </form>
</body>
</html>
